package com.winning.pmph.enumeration;

/**
 * 响应code枚举
 * @author yjh
 */
public enum RespCodeEnum {
    //响应成功
    SUCCESS("1900", "请求成功"),
    //响应失败
    FAIL("1901", "请求失败"),
    //token已失效
    TOKENEXPIRED("1902", "token已失效"),
    //token非法
    TOKENINVALID("1903", "token非法"),
    //token为空
    TOKENEMPTY("1904", "token为空"),
    //参数缺失
    PARAMEMPTY("1905", "参数缺失"),
    //应用不存在
    CLIENTEMPTY("1906", "应用不存在"),
    //应用被禁用
    CLIENTDISABLED("1907", "应用被禁用"),
    //应用key非法
    CLIEKEYINVALID("1908", "应用key非法"),
    //文件缺失
    FILEEMPTY("1909", "文件缺失"),
    //队列已满
    QUEUEFULL("1910", "上传队列已满"),
    //ip黑名单
    IPBLACK("1911", "ip黑名单"),
    //某文件分片上传失败
    CHUNKUPLOADFAIL("1912", "分片文件上传失败"),

    DOMAINEMPTY("1913", "资源管理服务域名为空"),

    OPENCHUNKFAIL("1914", "开启分片上传失败"),
    //其它异常
    OTHERERROR("2000", "其它异常");

    private final String code;
    private final String msg;
    RespCodeEnum(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return this.code;
    }
    public String getMsg() {
        return this.msg;
    }
}
